1. Field of the Invention
The present invention relates to the field of computer operating systems and application development, in particular a programming model for developing host computer applications on a computer system having a coprocessor.
2. Description of the Related Art
Computer systems utilizing coprocessors for performing specialized functions or increasing processor performance and functionality, are well known in the art. Coprocessors are used for generating enhanced graphical images and performing arithmetic functions. As multimedia applications are being developed for computer systems, the desire and need for digital signal processing (DSP) coprocessors has emerged. Mulitmedia applications refer to applications which integrate different forms of communication to create a more effective presentation of information, e.g. a "document" that has text, video and audio portions.
Digital signal processing is the processing of digitized signals. Digitized signals are digital representations of analog signals. Analog signals may be sounds, images, speech or any one or more ensembles of one or more series with a dependent variable (e.g. time or space). To correctly process such digitized signals, it is necessary to know at what sample rate the signal was digitized and the format of the digital bits used to represent the analog signal. With this information, the digitized signal can be manipulated by application software programs. The resulting data can then be stored or converted back into an analog signal. An application program that utilizes a DSP coprocessor is hereinafter referred to as a host DSP application, while the code that is actually executing on the DSP is referred to as a DSP program. For example, a host DSP application may be a program to create and edit music, while a DSP program may be used for compressing, decompressing and mixing stored audio data for playback.
In some instances, host DSP applications are supported via dedicated hardware components, e.g. a modem or audio interface or a graphical display interface. It is desirable to have a single DSP coprocessor support multiple applications for inherent economies, e.g. reduced system hardware costs. With the growth of multimedia applications, such digital signal application requirements will grow accordingly.
The integration of a coprocessor into a computer system will typically take one of three forms: shared command stream, multi-processing and satellite. In a shared command stream integration, coprocessor task requests are placed directly into an input stream processed by the host processor. The way the coprocessor receives the tasks may be in one of two manners. In a first manner, the coprocessor tasks are forwarded by the host processor to the coprocessor for execution. In a second manner, the coprocessor monitors bus activity looking for coprocessor instructions. Upon detection of a coprocessor instruction, the coprocessor communicates with the host processor, e.g. via a hardware handshake, and processes the instruction. A coprocessor for carrying out mathematical equations, such as a floating point processor, will typically have a shared command stream integration.
In a multi-processing integration, the coprocessor has it's own operating system. Communication with the host processor operating system is through shared memory, hardware mailboxes or other resources. In a satellite integration, the coprocessor may receive commands, programs and data from a host processor for carrying out tasks. Typically, a coprocessor shares an I/O channel or other limited interconnection means, rather than sharing memory through a common bus.
For each of the aforementioned integration techniques, the question of optimizing usage of the host processor and coprocessor resources arises. In a shared command stream or command driven integration, the coprocessor remains idle during periods of time when no tasks are being directed to it, but may become a source of a processing bottleneck during periods of heavy usage. In a multiprocessor integration, functions that may be best carried out by the host processor may be performed by the coprocessor, thus negatively impacting total system performance. It is desirable to have synergistic operation of the host processor with the coprocessor.
Known DSP implementations integrate the DSP coprocessor as a satellite coprocessor to the main processor. Such implementations have proven to limit DSP functionality and the end value of the DSP itself, to the customer. DSP coprocessors typically have a dedicated operating system. This has resulted in requiring a programmer developing a host DSP application or a DSP program to be familiar with the host computer system operating environment, the DSP operating environment and programming techniques or algorithms specific to the type of data (e.g. digitized audio data) being manipulated. In many cases this is inefficient because a single programmer would not have such skills and would have to acquire them. For example, a programmer developing a host DSP application may not have any skills in the DSP operating environment or in the algorithms used for manipulating a specific type of data. Conversely, a programmer developing a DSP program may not have any skills regarding the host operating environment.
A known technique for simplifying host application development utilizing a provided system resource is through an Application Programming Interface (API). An API is typically a predefined set of function (e.g. macro) calls which can be used to access and utilize the resource in a predefined manner. However, such APIs do not address the situation wherein a host application developer requires flexibility in the manner in which they utilize a resource. If a host application developer desired to use the resource in an alternative manner, the API would typically be bypassed thus requiring skills in programming the resource.
It is an object of the present invention to provide an environment wherein application and coprocessor programmer skills are best utilized. To this end, an environment where an host DSP application developer need not be concerned about programming a DSP, and a DSP program developer need not be concerned about programming the host environment, is desirable.
It is a further object of the present invention to optimize total system throughput through the division of labor between a host processor and a coprocessor.
Finally, it is an object of the present invention to provide for the simultaneous servicing of multiple host applications through one or more coprocessors.